package com.ztjava.ask.validator;

import com.jfinal.core.Controller;
import com.ztjava.core.Constant;
import com.ztjava.core.base.BaseValidator;

public class AddAnswerValidator extends BaseValidator{

	@Override
	protected void validate(Controller c) {
		setShortCircuit(true);
		validateRequired("question_id", Constant.MESSAGE, "缺少问题ID！");
		validateString("content", 3, 500, Constant.MESSAGE, "3-500个字符！");
	}

}
